<?php
namespace app\applet\controller;
class Home extends Applet {
    /**
     * 首页
     */
    public function index(){

        $data = input('post.');

        //轮播
        $carousel = db('carousel') -> where(array('uid'=>WID,'type'=>'mall')) -> find();
        $carousel['carousel'] = serializeMysql($carousel['carousel'],1);
        foreach($carousel['carousel'] as $k=>$v){
            if($v['imgpath']){
                $swiper[] = C('WEB_ABSOLUTE_URL').substr($v['imgpath'],1);
            }
        }
        $rdata = array(
            'carousel'		=> $swiper,
        );
        return json($rdata);
    }
    /**
     * 提交页
     */
    public function order(){

    }
    /**
     * 详情
     */
    public function detail(){

    }
    /**
     * 记录页
     */
    public function record(){

    }
}